package servicesImp.specific;


import base.response.OffsetLimitPage;
import com.github.pagehelper.Page;
import com.github.pagehelper.PageHelper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import services.specific.AdminCheckExpertServices;
import wt.dao.specific.AdminCheckExpertMapper;
import wt.entity.specific.AdminCheckExpert;

import java.util.List;


/**
 * Created by Administrator on 2017/9/13.
 */
@Service
public class AdminCheckExpertServicesImp  implements AdminCheckExpertServices{

    @Autowired
    AdminCheckExpertMapper adminCheckExpertMapper;

    public OffsetLimitPage select(String expertName, String tableName, Integer offset, Integer limit) throws Exception {

        PageHelper.offsetPage(offset, limit);
        List<AdminCheckExpert> recordList =adminCheckExpertMapper.select(expertName,tableName);
        return  new OffsetLimitPage((Page)recordList);
    }
}
